using System;  
using System.Collections; 
public class ResponseBeanParse
{
	public  ResponseBeanParse(){}

	public ProtocolResponseBase parse(ByteBuffer data)
	{
		ProtocolResponseBase response=null;
		short msgCode=data.ReadShort();
		switch(msgCode)
		{
		<#list resps as resp>
		case MessageCode.${resp.consName}:
		{
			response=new ${resp.name}ResponseMsg();
			response.readData(data);
			break;
		}
		</#list>
			
			default:
			{
				break;
			}
		}
		return response;
	}
}
